.. _Description of baseline selection parameters.json#/: Description of baseline selection parameters ============================================ Names of baselines to be matched. It can be given as either a vector of vectors or as a casacore MSSelection string. These two methods are mutually exclusive. When in doubt, use the second syntax. Syntax 1: vector of vectors ########################### If given as a vector, a vector element can be a vector of two names giving the stations forming a baseline `:` 1. ``baseline=[ [CS001,RS003], [CS002,RS005] ]`` selects baselines CS001-RS003 and CS002-RS005. Each name can be a shell-type pattern (with wildcards * ? [] or {}) `:` 2. ``baseline=[ [CS*,RS*], [CS*,CS*], [RS*,RS*] ]`` or ``baseline=[ {CS*,RS*},{CS*,RS*} ]`` selects all baselines (also autocorrelations) between core and remote stations. Note that the wildcard characters {} mean OR. They can be used to pair groups of stations (quotes are needed) `:` 3. ``baseline=[ ["{CS001,CS002}","{RS003,RS005}"] ]`` selects baselines CS001-RS003, CS001-RS005, CS002-RS003, and CS002-RS005. Besides giving a baseline, it is also possible to give a single station name (possibly wildcarded) meaning that only baselines containing that station will be selected. It is a bit hard to select international stations using this syntax. Syntax 2: casacore baseline selection ##################################### This syntax is also described in `this note `__ and `Casacore note 263 `__. The advantage of this syntax is that it is more concise and that besides a station name pattern, it is possible to give a station number. The examples above can be expressed as `:` 1. ``baseline=CS001&RS003;CS002&RS005`` for baselines CS001-RS003 and CS002-RS005. 2. ``baseline=[CR]S*&&`` for baselines (also autocorrelations) between RS and CS stations (i.e. discard all baselines involving international stations). 3. ``baseline=CS001,CS002&RS003,RS005`` for CS001-RS003, CS001-RS005, CS002-RS003, and CS002-RS005 Note that & means cross-correlations, && means cross and auto, &&& means auto only. If there is nothing to the right of the ampersand(s), it means the right bit will be equal to the left bit. Therefore, `baseline=CS*&&` selects the same as `baseline=CS*&&CS*` which selects all cross and auto-correlations of the core stations. International stations can be selected most easily using negation `:` 4. ``baseline=^[CR]S*&&*`` to select all baselines containing at least one international station; read this as "Cross and autocorrelations between (not core or remote stations) and any other station". 5. ``baseline=^[CR]S*&&`` to select baselines containing ONLY international stations; read this as "Cross and autocorrelations between (not core or remote station) and (not core or remote station)". Sometimes the baselines between the HBA ears of the same station should be deselected `:` 6. ``^/(.*)HBA0&\1HBA1/`` (the `\\1` is back substitution for the `(.*)` on the left). Without the caret only such baselines are selected. Note`:` in the ``msin`` step only the baseline selection syntax is possible. Also note that, currently, only the first way works properly when selecting baselines after a station has been added. The reason is that the second way looks in the original ANTENNA table to find matching station names, thus will not find the new station `.` Parameters to select on baseline can be used in the steps preflagger and filter. The step msin.baseline only supports syntax variant 2. Filtering out some stations ########################### 7. ``baseline=!CS401HBA0,CS401HBA1,RS205HBA`` filters out all baselines involving ``CS401HBA0``, ``CS401HBA1`` or ``RS205HBA``. Full examples ############# Say we have a measurement set containing ``CS001HBA0``, ``CS001HBA1``, ``RS307HBA``, ``IT509HBA``. Then the following examples yield the given baselines: 8. ``baseline=[CR]S*&&``: keeps all baselines (also autocorrelations) with ``CS001HBA0``, ``CS001HBA1``, ``RS307HBA``. So discard international stations. 9. ``baseline=^CS001HBA0,RS307HBA&&``: keeps all baselines (also autocorrelations) with ``CS001HBA1`` and ``IT509HBA``. So discard ``CS001HBA0`` and ``RS307HBA``. If you want to debug your baseline selection syntax, you can query the baselines in a measurement set with ``taql select distinct mscal.ant1name(), mscal.ant2name() from bla.MS`` .. _Description of baseline selection parameters.json#/inputs: inputs ****** .. _Description of baseline selection parameters.json#/inputs/corrtype: corrtype ++++++++ :type: ``string`` :default: ``""`` :doc: Correlation type to match? Must be ``auto``, ``cross``, or an empty string (= all) `.` .. _Description of baseline selection parameters.json#/inputs/baseline: baseline ++++++++ :type: ``baseline?`` :default: ``""`` :doc: See above `.` .. _Description of baseline selection parameters.json#/inputs/blrange: blrange +++++++ :type: ``double?`` :default: ``[]`` :doc: Zero or more ranges of physical baseline lengths (in m). A baseline matches if its length is within one of the ranges. E.g., ``blrange=[0,10000, 100000, 1e30]`` matches baselines shorter than 10km and baselines longer than 100km `.`